0.24.0 update.#1
Open
sidav wants to merge 869 commits into
Open
Conversation
As a followup to 1cd5daa, this commit adds code to upgrade Wyrmbane's tile as the lance grows more powerful.
UI cutoffs prevent any any UI layers with index <= the cutoff index from being displayed. If there's no cutoff, the cutoff index should be -1; the old value of 0 was causing the lowest UI layer to not be unhidden.
The previous implementation added a tooltip timer before blocking for the next SDL event, and removed it before returning. If resize or move events were received, however, the function would return early, and the timer would never be removed and would instead timeout periodically. Subsequent move events would add additional timers, leading to a flood of timeouts clogging up the event loop. This new implementation only ever adds a timer when the mouse is moved, and timers only fire once. remove_timer() is also changed to take an int& for convenience.
The menu already ellipsizes menu items as needed based on screen size.
Widgets may query the current scissor region to reduce render calls, e.g. by not rendering children or other elements that are not visible. During a regular layout and render cycle, the UI framework pushes a scissor region of the entire screen, so this works fine. When doing ad-hoc rendering (while we transition to full use of the UI framework), this is not the case, which caused crashes.
m_wrapped_lines being empty caused the size request calculation to yield a natural size (0 lines) smaller than the minimum size (1 line), causing assertion failures.
The handle_terminal_resize() call in startup.cc (added in e03bc23) seems to no longer be required, since the code to determine the HUD size based on species (added in the same commit) is no longer present, and thus the HUD should not need to be resized any more. This permits some minor simplification of handle_terminal_resize().
Pre-wrapping to a given screen-width should be avoided in general because the screen can be resized. In addition, the GOTO_CRT region size is not a well-defined concept on local tiles.
The `get_tension` check is not well-defined without a player, and also isn't used for monster attackers. Also, the singing sword was shouting at the player's location, not the attacker (which caused another crash in arena).
Because of an incorrect formula added in a559921, Mara and rakshasa clones had 200% hp of their original instead of 50%. Regular monsters copied via `cast_phantom_mirror()` had 286% hp and max hp instead of 35%.
Debug builds unsurprisingly spew large numbers of messages, so repeatedly showing a more prompt is very inconvenient.
The call to expand_mlist() assumes that the monster list has its initial position and size; this is not the case if you run arena mode more than once without quitting the game in between. After this fix, the UI is still broken if you run arena then a regular game. I tried using an unwind_var, but that caused crashes, and a better fix is in the works anyway (using the widget toolkit).
A copy created via rakshasa's Phantom Mirror has only 35% of the target's hp and max hp. If the original monster is almost dead (1-2 HP), its copy will have 0 hp, which crashes the game. Fix this by giving cloned monsters at least 1 hp. Also, it allows rakshasas to clone lurking horrors, who always spawn with only 1 hp.
Apparently it was previously possible, for some definitions of the word 'possible', to have multi-key macro binds; e.g. 'ab' -> foo. I couldn't actually get any of these to trigger, however, even when using xdotool to quickly deliver keypress events. This commit simplifies the complicated macro expansion code that resulted. Saved macros that have multi-key binds are silently truncated to the first character. This commit also slightly refactors filtering of empty macros.
This makes the difference between getchm and getch_with_command_macros slightly clearer.
While you could theoretically have multiple keys returned from _getch_mul, in practice I never managed to make it happen, and it's preferable for the code paths through the macro system to be as simple as possible.
We only ever add a single key at a time to the macro buffer; better to enforce that. This also asserts in remap_key() that the macro buffer is empty before remapping a key; this must be the case because ui::pump_events() first tries to get a key from the macro buf, and only remaps a new key if there is no macro key available.
Returning std::move() here is fine because the parameter is an rvalue reference, so RVO is not relevant, and a move() call is required to prevent a copy.
Spell range strings don't use colour codes any more. As for explore discoveries, it's simpler to parse the tagged string and then use the dedicated width() method.
(cherry picked from commit 099c3e1)
(cherry picked from commit 710a5d0)
(cherry picked from commit 883716c)
A better fix would be to use the just-removed align_self, but I'd rather not revert that removal, and adding a better implementation would be too disruptive at this point (feature freeze). (cherry picked from commit 6cf4ce5)
(cherry picked from commit 3121d2d)
Updated tiles for Sif Muna's Divine Exegesis and Fedhas' Wall of Briars, Overgrow, and Grow Oklob abilities. (cherry picked from commit 29a1220)
This fix drops mouseup events if the UI layout has been changed since the corresponding (well, previous) mousedown event. This fixes a bug where the loading screen would transition to the main menu on mousedown, and the mouseup event would then activate the button underneath the cursor. I'm not sure this is the best way to fix this. Some alternatives: - have the loading screen transition on mouseup - have the loading screen "swallow" the mouseup event explicitly via some new API - have menu buttons only activate on mouseup if they also received a corresponding mousedown (cherry picked from commit 47823c4)
(cherry picked from commit 6afad29)
This is necessary if scoring (or perhaps sequell) is to do anything interesting with seeded games. This commit adds the seed for all game types, since even for normal games the seed is revealed on game end. Milestones do not have this field for any game type. (cherry picked from commit 6c54e25)
(cherry picked from commit 3d4e485)
(cherry picked from commit 1393849)
It is tactically useful to know how much damage is due to flay. For example, it matters in deciding whether to quaff cancellation or who to attack. This information is already revealed to the player, but not in a convenient way. At the moment the careful player must pay attention to what the sources of damage are as the fight proceeds in order to know this; and, if this is neglected, it is difficult to recover the information from the message log later in the fight. This commit reveals that information more straightforwardly by adding it to the flay status light. I show a number instead of a more coarse-grained indicator. Note that otherwise the conscientious player will still want to keep track manually of damage since they can get better information that way. The damage is displayed as a negative number for consistency with the similar corrosion status light. (cherry picked from commit f18fdeb)
It turns out that multi-key macros were used for keybinds for
multi-character sequences sent by some terminals corresponding to
special keys. For example, under the VT100 standard, \{27}Ov is sent by
numpad 6. Another example: on OS X, option+arrow keys send
multi-character escape sequences as well (maybe even outside of
terminal). This sequence of commits broke such old macro files, and even
worse, tended to break ESC, since nearly all of these sequences are ESC
sequences. We'll need to rethink how to simplify this.
Some of these simplifications might be independent of the current revert
project and could be restored...
This reverts commit 049a785.
(Note: also a partial revert of d158fba, 0b1efcb, 0e779d2)
This reverts commit 678ee33.
This reverts commit 5a8975c.
This reverts commit 3ea5ddb.
(cherry picked from commit 72dcfe0)
At first glance, this may appear to be a feature, but it is in fact a bug: the bug is that paste doesn't work for crt-emulated input. Implementing this as an actual textbox is the only way I've found to get this to work in webtiles. This doesn't materially change the implementation of the seed selection ui for console/local tiles; it is just as bad as ever. (cherry picked from commit 74baf03)
Not sure what the conditions are that trigger this, but probably at least game_exit::abort. (cherry picked from commit 8315797)
(cherry picked from commit b8d28a4)
(cherry picked from commit 1381ef2)
(cherry picked from commit 2ac9325)
(cherry picked from commit 75acf02)
The vault cheibrodos_wizard_tower placed on-average 3 8-tier monsters at Lair depth, which is fairly nasty. This commit reworks the monster and loot placement to better scale with depth, starting with 1.25 monsters at D:7-9. The monster set now includes a possible deep elf annihilator in Dungeon, but only at depths where those are possible 8 spawns, and with a small chance. The monster count in Elf has been increased as well. The vault range is now increased to include D:13-D:$. The loot now has some thematic aux armor, randbooks, and staves mixed in, and the loot scales in count with depth. (cherry picked from commit f0389da)
This has been broken for a while; it was a mid/mindex confusion. I've also refactored the call so that it will better handle the case where your summon does before the fineff fires. (cherry picked from commit c466198)
We'll see if players think this is too spammy or too obscure, but for 0.24.0 at least this will be helpful for testing any seed issues that come up. (cherry picked from commit 9c56bcb)
(cherry picked from commit 72b0ba0)
0.24 "Plants vs. Vampires"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added an entry to crawl-ref/source/Android.mk. Also added the same entry to crawl-ref/source/android-project/jni/src/Android.mk just because I can't fugure out which of the files is the main one.
The CrystaX NDK dropped the 4.8 toolchain, so I also updated NDK_TOOLCHAIN_VERSION to 4.9 in crawl-ref/source/Application.mk, build still passess.
All the other changes are just from 0.24.0 in crawl main repo if I didn't screw everything up.